<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>

        // //模板字符串
        // let name=`Jack`
        // let message=`Hello World`

        //好处
        //普通字符串不支持换行
        //let htlStr='<div class="hot-good-box"><h1>热门商品</h1><p>卖爆了</p></div>'

        let htlStr=`<div class="hot-good-box">
            <h1>热门商品</h1>
            <p>卖爆了</p>
            </div>`
        
        console.log(htlStr)
        // let name='Bit'
        // let age=18
        // //let str='My name is'+name+',I am '+age+' years old,I am '+(age>=18? '已成年':'未成年')

        // let str=`My name is ${name}, I am ${age} years old, I am ${age>=18? `已成年`:`未成年`}`
    </script>
</body>
</html>